﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="USJ.aspx.cs" Inherits="USJ" %>

<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="webdiyer" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>50CMS后台框架</title>
    <link rel="shortcut icon" href="favicon.ico">
    <link href="../css/bootstrap.min.css?v=3.3.6" rel="stylesheet">
    <link href="../css/font-awesome.css?v=4.4.0" rel="stylesheet">
    <link href="../css/animate.css" rel="stylesheet">
    <link href="../css/style.css?v=4.1.0" rel="stylesheet">

    <link href="../css/plugins/footable/footable.core.css" rel="stylesheet" />

    <link href="../50/style.css" rel="stylesheet" />
    <link href="../css/plugins/sweetalert/sweetalert.css" rel="stylesheet" />
    <script src="../Js/plugins/sweetalert/sweetalert.min.js"></script>
    <style>
        .msgtable td {
            padding: 0px;
        }

        .dropList {
            display: inline-block;
            float: left;
            margin-top: -10px;
            position: relative;
            padding: 0;
            margin-left: 150px;
        }
    </style>
</head>
<body>
    <form id="form1" runat="server" class="form-horizontal m-t">
        <div class="wrapper animated fadeInRight">
            <div class="row">
                <div class="col-sm-12">
                    <div class="ibox float-e-margins">
                        <div class="ibox-title">
                            <h5>内容管理</h5>

                            <div class="dropList" style="margin-left: 60px;">
                              <%--  <asp:TextBox ID="txtSNickName" runat="server" placeholder="请输入微信昵称" Style="padding: 5px 12px;"></asp:TextBox>&nbsp;&nbsp;--%>
                                <asp:TextBox ID="txtUtel" runat="server" placeholder="请输入手机号码或姓名" Style="padding: 5px 12px;"></asp:TextBox>&nbsp;&nbsp;<asp:Button ID="btnSearch" runat="server" Text="查询" OnClick="btnSearch_Click" CssClass='btn btn-primary btn-sm' />
                            </div>

                            <div class="ibox-tools">
                                <a onclick="location.reload();" class="btn btn-primary btn-xs"><i class="fa fa-refresh">&nbsp;&nbsp; 刷 新</i></a>
                                <!--a href="#" id="Add" class="btn btn-primary btn-xs"><i class="fa fa-plus"></i>&nbsp;&nbsp; 新增内容</!--a-->

                            </div>
                        </div>
                        <div class="ibox-content">

                            <asp:Repeater ID="rptList" runat="server" >
                                <HeaderTemplate>
                                    <table class="footable table table-stripped toggle-arrow-tiny" data-page-size="10">
                                        <thead>
                                            <tr>
                                                <th align="center">申请ID</th>
                                                <th align="center">GUID</th>
                                                            <th align="center">申请人</th>
                                                <th align="center">上级信息</th>

                                                 <th align="center">申请时间 </th>
                                                
                                                <th align="center">业绩 </th>


                                                                 <th align="center">现在级别 </th>
                                                                <th align="center">申请级别</th>
                                 
                                      <th align="center"> 上家审核 </th>
                                              
                                               

                                                <th align="center">操作</th>
                                            </tr>
                                        </thead>
                                        <tbody>
                                </HeaderTemplate>
                                <ItemTemplate>
                                    <tr class="gradeX">
                                        <td><%#Eval("FID")%></td>
                                        <td><a onclick="lookChild('<%#Eval("FName")%>')"><%#Eval("FName")%></a></td>
                                        
                                         <td>  <%#_rky.getUwxandTElByguid(Convert.ToString(Eval("FName")))%></td>

                                         <td>  <%#_rky.getUpByguid(Convert.ToString(Eval("FName")))%></td>


                                             <td><%#string.Format("{0:g}", Eval("FTime"))%></td>
                                          <td>
                                            <a onclick="lookYJ('<%#Eval("FName")%>')"  class="btn btn-danger btn-xs">查看业绩  ￥<%#_rky.getYJByGUID(Convert.ToString(Eval("FName")))%></a>
                                          </td>

                                        <td ><span  class="btn btn-danger btn-xs"> <%#_rky.getStateByguid(Convert.ToString(Eval("FName")))%></span> </td>

                                       <td > <span class="btn btn-primary btn-xs"><%#Eval("FTitle")%>  </span> </td>
                                        
                                    <td > <span class="btn btn-primary btn-xs"> <%#getSH(Convert.ToString(Eval("FReContent")) ,Convert.ToString(Eval("FLock")))%>  </span> </td>
                               
                           

                                         <td>
                                             
                                             <a onclick="EditParent('<%#_rky.getUIDByGuid(Convert.ToString(Eval("FName")))%>')"  class="btn btn-info btn-xs"><i class="fa fa-pencil"></i>修改</a>
                                             &nbsp;
                                            
                                           </td>
                                    </tr>
                                </ItemTemplate>
                                <FooterTemplate>
                                    </tbody>
                                </table>
                                </FooterTemplate>
                            </asp:Repeater>

                            <webdiyer:AspNetPager ID="AspNetPager1" runat="server" PageSize="10" FirstPageText="首页" LastPageText="末页" NextPageText="下一页" PrevPageText="上一页" AlwaysShow="true" OnPageChanging="AspNetPager1_PageChanging" CssClass="paginator" CurrentPageButtonClass="cpb">
                            </webdiyer:AspNetPager>
                            <div class="spClear"></div>
                            <div style="line-height: 30px; height: 30px;">
                                <div id="Pagination" class="right flickr"></div>
                            
                            </div>


                        </div>
                    </div>
                </div>
            </div>
        </div>
    </form>



    <!-- 全局js -->
    <script src="../js/jquery.min.js?v=2.1.4"></script>
    <script src="../js/bootstrap.min.js?v=3.3.6"></script>

    <!-- 自定js -->

    <script src="../js/plugins/footable/footable.all.min.js" type="text/javascript"></script>
    <script src="../js/content.js" type="text/javascript"></script>
    <script type="text/javascript" src="../js/layer/layer.js"></script>

    <!-- iCheck -->
    <script src="../js/plugins/iCheck/icheck.min.js"></script>
    <script>
        $(document).ready(function () {
            $('.i-checks').iCheck({
                checkboxClass: 'icheckbox_square-green'

            });
        });
    </script>

    <script type="text/javascript">
        $(document).ready(function () { $(".footable").footable(); });
    </script>
    <script type="text/javascript">


        $(function () {
            $("#Add").click(function () {

                parent.layer.open({
                    type: 2,
                    title: '添加新内容',
                    shadeClose: true,
                    shade: 0.8,
                    area: ['100%', '100%'],
                    content: 'Add.aspx',  //iframe的url
                    end: function () {

                        location.reload();

                    }
                });

            });

        });



        function lookYJ(ID) {
            layer.open({
                type: 2,
                title: '会员业绩',
                shadeClose: true,
                shade: 0.8,
                area: ['90%', '90%'],
                content: './User_YJ.aspx?Guid=' + ID,  //iframe的url
                end: function () {
                }
            });
        }
        

        function EditUser(ID, type) {
            parent.layer.open({
                type: 2,
                title: '修改内容',
                shadeClose: true,
                shade: 0.8,
                area: ['90%', '90%'],
                content: '/Admin/User/wxUserAdd.aspx?id=' + ID, //iframe的url
                end: function () {
                    location.reload();
                }
            });
        }

        function CZ(ID, type) {
            layer.open({
                type: 2,
                title: '充值',
                shadeClose: true,
                shade: 0.8,
                area: ['90%', '90%'],
                content: 'cz.aspx?id=' + ID, //iframe的url
                end: function () {

                }
            });
        }

        function EditParent(ID, type) {
            layer.open({
                type: 2,
                title: '上级会员信息',
                shadeClose: true,
                shade: 0.8,
                area: ['80%', '80%'],
                content: './Parent_Detail.aspx?id=' + ID,  //iframe的url
                end: function () {

                }
            });
        }


        function lookChild(ID) {
            layer.open({
                type: 2,
                title: '会员信息',
                shadeClose: true,
                shade: 0.8,
                area: ['90%', '90%'],
                content: './User_Detail.aspx?Guid=' + ID,  //iframe的url
                end: function () {
                }
            });

            $('.btn-danger').click(function () {
                return confirm("删除后不可恢复，确定要删除吗？");
            });
        }
    </script>
</body>
</html>
